<include file="Public/header" title="产品列表" />
<div id="page-wrapper">
    <ol class="breadcrumb">
        <li class="breadcrumb-item">
          <a href="/admin.php">首页</a>
        </li>
        <li class="breadcrumb-item active">产品管理</li>
      </ol>
    <div class="row">
        <div class="col-md-6">
            <a href="{:U('product/add')}" class="btn btn-success">添加产品</a>
        </div>

    </div>
    <table class="table table-hover table-striped">
        <thead>
            <tr>
                <th>编号</th>
                <th>产品名称</th>
                <th>发布时间</th>
                <th>操作</th> 
            </tr>
        </thead>
        <tbody>
        <foreach name="data" item="v">

                <tr>
                    <td>{$v.product_id}</td>
                    <td><a href="{:U('product/detail?id=')}{$v.product_id}">{$v.title}</a></td>
                    <td>{$v.add_time|date="Y/m/d H:i:s",###}</td>
                    <td><a href="{:U('product/update?id=')}{$v.product_id}">编辑</a> | <a href="{:U('product/delete?id=')}{$v.product_id}" style="color:red;" onclick="javascript:return del('您真的确定要删除吗？\n\n删除后将不能恢复!');">删除</a></td>
                </tr>

        </foreach>
        </tbody>
    </table>
    <div class="clearfix"></div>
    {$page}
    
</div>
<include file="Public/footer" />